unit uFMain;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, Menus;

type
  TFMain = class(TForm)
    MainMenu1: TMainMenu;
    N1: TMenuItem;
    N4: TMenuItem;
    N5: TMenuItem;
    N2: TMenuItem;
    N3: TMenuItem;
    procedure N4Click(Sender: TObject);
    procedure N5Click(Sender: TObject);
    procedure N2Click(Sender: TObject);
    procedure N3Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  FMain: TFMain;

implementation

uses
  uFOpera, uFDept, uFMzPatient;

{$R *.dfm}

procedure TFMain.N4Click(Sender: TObject);
begin
  close;
end;

procedure TFMain.N5Click(Sender: TObject);
begin
  if Application.FindComponent('FOpera') = nil then
    FOpera := TFOpera.Create(Application);
  FOpera.show;
end;

procedure TFMain.N2Click(Sender: TObject);
begin
  if Application.FindComponent('FDept') = nil then
    FDept := TFDept.Create(Application);
  FDept.Show;
end;

procedure TFMain.N3Click(Sender: TObject);
begin
  if Application.FindComponent('FMzPatient') = nil then
    FMzPatient := TFMzPatient.Create(Application);
  FMzPatient.Show;
end;

end.

